#include "windows.h"

void init_windows(void)
{
    uint8_t idx = 0;
    uint8_t win_num = 0;

    Win_init win_init[] = {
        {win00_desktop_init},
        {win01_weather_init},
        {win02_setting_init},
        {win03_digimon_init},
        {win04_othermo_init},
    };

    win_num = sizeof(win_init) / sizeof(win_init[0]);

    windows = (Windows *)malloc(sizeof(Windows) * win_num);
    if (windows == NULL)
    {
        printf("windows malloc error!\n");
        return;
    }

    for (idx = 0; idx < win_num; idx++)
    {
        win_init[idx].init();
    }
}